<div class="container-fluid">

    <app-page-title title="Code Examples" [breadcrumbItems]="breadCrumbItems"></app-page-title>

    <div class="row">
        <div class="col-lg-12">
            <div class="card">
                <div class="card-body">
                    <h4 class="card-title mb-4">Edit Code Item</h4>
                    <form [formGroup]="codeExampleForm">
                        <div class="form-group">
                            <label for="titleInput">Title</label>
                            <input formControlName="title" type="text" class="form-control" id="title"
                            placeholder="Add New Title" onfocus="this.placeholder = ''" onblur="this.placeholder = 'Add New Title'">
                        </div>
                        <div class="form-group">
                            <label for="langInput">Language</label>
                            <input formControlName="code_lang" type="text" class="form-control" id="code_lang"
                            placeholder="Code Example Language" onfocus="this.placeholder = ''" onblur="this.placeholder = 'Code Example Language'">
                        </div>
                        <div class="form-group">
                            <label for="Description">Code</label>
                            <textarea formControlName="content" class="form-control" id="content" rows="20"
                            placeholder="Code Example Description" onfocus="this.placeholder = ''" onblur="this.placeholder = 'Code Example Description'">
                            </textarea>
                        </div>
                        <div class="text-right">
                            <button (click)="updateCodeExampleItem()" class="btn btn-success mr-2"
                                type="button">Update</button>
                            <button [routerLink]="['/code-example/view']" class="btn btn-danger"
                                type="button">Cancel</button>
                        </div>
                    </form>
                </div>
            </div>
        </div>
    </div>

</div>